<?php
/**
 *
 * @param Ctrl $ctrl
 */
function AuthAfter($ctrl) {
	
	$auth = $ctrl->plugins['Auth'];
	
	$viewVars = array(
			'logged' => $auth->logged(),
	);
	
	if ($viewVars['logged']) {
		$viewVars['uname'] = $_COOKIE[COOKUSER];
	}
	
	$ctrl->response->auth($viewVars);

}